﻿


Public Class SaveItem
    Public Function Save(ByVal item As Auction, ByVal ship As Shipping, ByVal img As List(Of Image)) As Boolean
        Dim db As New AuctionInfoDataContext
        item.Shippings.Add(ship)

        For Each auctionImage In img
            item.Images.Add(auctionImage)
        Next
        db.Auctions.InsertOnSubmit(item)
        db.SubmitChanges()
    End Function
End Class
